const { command, exists } = require('../../helper')
const merge = require('webpack-merge')

module.exports = new class {
	constructor(){
		const { appConfig } = command()
		const DefaultAppConf = require('../../app.config') 
		const userAppConf = exists(appConfig || 'app.config', true)
		return userAppConf ? merge({}, DefaultAppConf, userAppConf) : DefaultAppConf
	}
}